import React from 'react';
import { Spin } from 'antd';
import './index.less';

type IProps = {
  tip?: string;
};

const PageLoading = function PageLoading({ tip = '加载中，请稍后...' }: IProps) {
  return React.createElement(
    'div',
    { className: 'page-loading' },
    React.createElement(Spin, { size: 'large', tip }),
  );
};

export default PageLoading;
